fix(51301): Fixing an unused import at the end of a line removes the newline#51320
Conversation
|
I think you're hitting exactly the problem I was when I tried to quick fix this 😅 |
|
😇 |
|
I tried to fix this last night and you figured out that second hurdle (which is where I gave up). Nice! This seems fine to me, but I have no idea what's good/bad for this part of the code. |
|
FWIW this is a related case that I think is also this same bug: function foo(
a: number, b: number,
c: number,
) {
return a + c;
}Removing I don't mind a targeted fix, of course. Would be great to have this in 4.9. |
|
Thanks for the added tests. I think one could also do the same thing as parameters for type parameters as well. I've modified the PR to eliminate the new parameter (make it always true) and everything passes, which does seem to match my intuition. |
jakebailey
left a comment
There was a problem hiding this comment.
This seems correct to me, but interested in what others think.
Fixes #51301